size = int(input("请输入三角形长度："))

# 左下
print("左下：")
for i in range(1, size + 1):
    print("*" * i)

# 右下
print("右下：")
for i in range(1, size + 1):
    print(" " * (size - i) + "*" * i)

# 左上
print("左上：")
for i in range(size, 0, -1):
    print("*" * i)

# 右上
print("右上：")
for i in range(size, 0, -1):
    print(" " * (size - i) + "*" * i)

    